package sctu.edu.java.year2016.team01.zhuming.day20160605.practice;

import java.util.HashSet;
import java.util.Iterator;
import java.util.Set;

/**
 * Created by Administrator on 2016/6/11.
 */
public class Collection {
    public static void main(String[] args) {
        Set<People> set = new HashSet<People>();
        set.add(new People(1102l, "tom"));
        set.add(new People(11022, "bob"));
        set.add(new People(11023, "jime"));
        set.add(new People(11024, "ming"));
        Iterator<People> it = set.iterator();

        while (it.hasNext()) {
            it.next();
            System.out.println("   " + it.next());
        }

    }


}